import request from '@/utils/request'

// 查询户口管理列表
export function listResidence(query) {
  return request({
    url: '/residence/residence/list',
    method: 'get',
    params: query
  })
}

// 查询户籍数量
export function getCountResidence() {
  return request({
    url: '/residence/residence/selectCountResidence',
    method: 'get',
  })
}
// 查询户口管理列表
export function listAllResidence(query) {
  return request({
    url: '/residence/residence/listAll',
    method: 'get',
    params: query
  })
}

// 查询户口管理详细
export function getResidence(id) {
  return request({
    url: '/residence/residence/' + id,
    method: 'get'
  })
}

// 新增户口管理
export function addResidence(data) {
  return request({
    url: '/residence/residence',
    method: 'post',
    data: data
  })
}

// 修改户口管理
export function updateResidence(data) {
  return request({
    url: '/residence/residence',
    method: 'put',
    data: data
  })
}

// 删除户口管理
export function delResidence(id) {
  return request({
    url: '/residence/residence/' + id,
    method: 'delete'
  })
}
